HIV/AIDS Surveillance Data Analysis across Countries
The primary goal is to analyze information on HIV prevalence, incidence rates, and AIDS mortality from available studies, identifying the most vulnerable gender, sub-population, and geographic region.
Multiple dashboards/web pages reflecting the prevalence and incidence rates of HIV across countries and subgroups.
United States Census’s HIV/AIDS Surveillance Data Base
# Incidence
incidence <- read.csv("surveillance/data/hiv_incidence.csv") |>
janitor::clean_names() |>
select(-c(no_cases,no_deaths,prev_rate)) |>
rename(subpop = population_subgroup) |>
mutate(geographic_area = ifelse(
str_detect(geographic_area,"rural"),"rural",
ifelse(
str_detect(geographic_area,"semi"),"semiurban",
ifelse(
str_detect(geographic_area,"urban"),"urban", geographic_area
))))
## recode subpopulation
# sexually active, TB, STI : other non-representative
# pregnant women: other patients
# sex worker&clients: ?
# Patients:?
# HIV+ individuals:?
incidence = incidence |>
mutate(
subpop_pooled = ifelse(
str_detect(subpop, "(?i)police|military"), "Military/Armed Forces",
ifelse(
str_detect(subpop, "(?i)child|pediatric"), "Children",
ifelse(
str_detect(subpop, "(?i)drug|IVDU") & !str_detect(subpop, "(?i)STI|homo|prisoner|partner|sex worker"), "Intravenous Drug Users/Needle Sharers",
ifelse(
str_detect(subpop, "(?i)sex worker|bar") & !str_detect(subpop,"(?i)trans|IVDU|homo|MSM|drug|client"),"Sex workers",
ifelse(
str_detect(subpop, "(?i)transgender|homo|MSM|gay|TB|STI|sexually|prisoner|infants born|HIV2+|high risk|of HIV") & !str_detect(subpop, "(?i)sex worker|IVDU|drug|Testing center attendees"), "Other Non-Representative",
ifelse(
str_detect(subpop, "(?i)pts.|pregnant|Mothers") & !str_detect(subpop, "(?i)sex worker|IVDU|STI|homo|TB"), "Other Patients",
ifelse(
str_detect(subpop, "(?i)Blood|port|Testing center attendees|employer|contractor|textile|Wives|HIV-") , "General Population","Two Known Mixed Groups"))))))))
# unique(incidence$subpop[str_detect(incidence$subpop,"patient")]) for categorization
# unique(incidence$subpop[incidence$subpop_pooled=="Two Known Mixed Groups"])
incidence = incidence |>
mutate(subpop_pooled = ifelse(
subpop %in% c("Bisexuals","Clients of sex workers","High risk individuals","Partners of drug users","Blood transfusion recipients"),"Other Non-Representative",subpop_pooled),
subpop_pooled = ifelse(
subpop == "Sex workers & clients","Sex workers",subpop_pooled),
subpop_pooled = ifelse(
subpop == "Patients","Other Patients",subpop_pooled),
subpop_pooled = ifelse(
subpop %in% c("Heterosexuals","Adults","Individuals","Women","Various groups","Residents","Unspecified population","Truck drivers","Others","Adults - circumcised","Adults - uncircumcised","Factory workers", "General population", "Low risk groups","Fishermen","Workers","Esquineros","Trucking companies employees","Youths","Hospitality girls","Adolescents","Volunteers","Controls","Rural population","Employees","Commercial bank employees"),"General Population",subpop_pooled))
incidence |>filter(subpop == "Patients")
## sequence country_code geographic_area reference_date subpop
## 1 4 CHN Liangshan Prefecture 2011 Patients
## 2 6 CHN Liangshan Prefecture 2013 Patients
## 3 10 CHN Liangshan Prefecture 2013 Patients
## 4 5 CHN Liangshan Prefecture 2012 Patients
## 5 8 TWN Taiwan 2005-2010 Patients
## 6 7 TWN Taiwan 2005-2010 Patients
## subpop_code sex age source_id
## 1 L B ALL W0798
## 2 L B ALL W0798
## 3 L B ALL L1138
## 4 L B ALL W0798
## 5 L B ALL L1186
## 6 L B ALL L1186
## comments
## 1 Provider-initiated HIV testing & counseling. Included blood/blood products recipients, surgical & other pts. BED-CEIA.
## 2 Provider-initiated HIV testing & counseling. Included blood/blood products recipients, surgical & other pts. BED-CEIA.
## 3 Located in Sichuan Province. BED-CEIA.
## 4 Provider-initiated HIV testing & counseling. Included blood/blood products recipients, surgical & other pts. BED-CEIA.
## 5 Pts. w/ out Herpes Zoster.
## 6 Pts. w/ Herpes Zoster.
## data_type country site_name
## 1 I China, Mainland Liangshan Prefecture
## 2 I China, Mainland Liangshan Prefecture
## 3 I China, Mainland Liangshan Prefecture
## 4 I China, Mainland Liangshan Prefecture
## 5 I China, Taiwan Taiwan
## 6 I China, Taiwan Taiwan
## author year
## 1 Wang, Q., Y. Yao, S. Yang, et al. 2017
## 2 Wang, Q., Y. Yao, S. Yang, et al. 2017
## 3 Liang, P., Y. Gong, Q. Liao, et al. 2016
## 4 Wang, Q., Y. Yao, S. Yang, et al. 2017
## 5 Lee, Y., O. N. Nfor, D. M. Tantoh, et al. 2015
## 6 Lee, Y., O. N. Nfor, D. M. Tantoh, et al. 2015
## title
## 1 Estimation of HIV-1 Incidence with BED-CIAE among Clinical Patients in Liangshan Yi Autonomous Prefecture: 2011-2013
## 2 Estimation of HIV-1 Incidence with BED-CIAE among Clinical Patients in Liangshan Yi Autonomous Prefecture: 2011-2013
## 3 Estimation of HIV-1 Incidence with BED-CEIA among Multiple Populations in Liangshan Yi Autonomous Prefecture: 2013
## 4 Estimation of HIV-1 Incidence with BED-CIAE among Clinical Patients in Liangshan Yi Autonomous Prefecture: 2011-2013
## 5 Herpes Zoster as a Predictor of HIV Infection in Taiwan: A Population-Based Study
## 6 Herpes Zoster as a Predictor of HIV Infection in Taiwan: A Population-Based Study
## publication_information
## 1 Chinese Journal of AIDS and STD, vol. 23, no. 5, pp. 402-404, 420.
## 2 Chinese Journal of AIDS and STD, vol. 23, no. 5, pp. 402-404, 420.
## 3 Modern Preventive Medicine, vol. 43, no. 9, pp. 1675-1678.
## 4 Chinese Journal of AIDS and STD, vol. 23, no. 5, pp. 402-404, 420.
## 5 PLoS One, vol. 10, no. 11, e0142254, <http://www.ploseone.org>, accessed on July 12, 2016.
## 6 PLoS One, vol. 10, no. 11, e0142254, <http://www.ploseone.org>, accessed on July 12, 2016.
## virus_type inc_rate specimen_type test_type sampsize subpop_pooled
## 1 HIV1 0.17 B ELISA 1,739 Other Patients
## 2 HIV1 0.31 B ELISA 1,948 Other Patients
## 3 HIV 0.31 B ELISA 1,948 Other Patients
## 4 HIV1 0.41 B ELISA 1,731 Other Patients
## 5 HIV 0.01 B UNK N/A Other Patients
## 6 HIV 0.02 B UNK N/A Other Patients
incidence |> filter(str_detect(title,"Estimation of HIV-1 Incidence with BED-CIAE among Clinical Patients in Liangshan Yi Autonomous Prefecture"))
## sequence country_code geographic_area reference_date subpop
## 1 4 CHN Liangshan Prefecture 2011 Patients
## 2 6 CHN Liangshan Prefecture 2013 Patients
## 3 5 CHN Liangshan Prefecture 2012 Patients
## subpop_code sex age source_id
## 1 L B ALL W0798
## 2 L B ALL W0798
## 3 L B ALL W0798
## comments
## 1 Provider-initiated HIV testing & counseling. Included blood/blood products recipients, surgical & other pts. BED-CEIA.
## 2 Provider-initiated HIV testing & counseling. Included blood/blood products recipients, surgical & other pts. BED-CEIA.
## 3 Provider-initiated HIV testing & counseling. Included blood/blood products recipients, surgical & other pts. BED-CEIA.
## data_type country site_name
## 1 I China, Mainland Liangshan Prefecture
## 2 I China, Mainland Liangshan Prefecture
## 3 I China, Mainland Liangshan Prefecture
## author year
## 1 Wang, Q., Y. Yao, S. Yang, et al. 2017
## 2 Wang, Q., Y. Yao, S. Yang, et al. 2017
## 3 Wang, Q., Y. Yao, S. Yang, et al. 2017
## title
## 1 Estimation of HIV-1 Incidence with BED-CIAE among Clinical Patients in Liangshan Yi Autonomous Prefecture: 2011-2013
## 2 Estimation of HIV-1 Incidence with BED-CIAE among Clinical Patients in Liangshan Yi Autonomous Prefecture: 2011-2013
## 3 Estimation of HIV-1 Incidence with BED-CIAE among Clinical Patients in Liangshan Yi Autonomous Prefecture: 2011-2013
## publication_information virus_type
## 1 Chinese Journal of AIDS and STD, vol. 23, no. 5, pp. 402-404, 420. HIV1
## 2 Chinese Journal of AIDS and STD, vol. 23, no. 5, pp. 402-404, 420. HIV1
## 3 Chinese Journal of AIDS and STD, vol. 23, no. 5, pp. 402-404, 420. HIV1
## inc_rate specimen_type test_type sampsize subpop_pooled
## 1 0.17 B ELISA 1,739 Other Patients
## 2 0.31 B ELISA 1,948 Other Patients
## 3 0.41 B ELISA 1,731 Other Patients
check=incidence |>
filter(subpop_pooled != "Two Known Mixed Groups") |>
group_by(subpop_pooled,subpop) |>
summarise(n=n())
## `summarise()` has grouped output by 'subpop_pooled'. You can override using the
## `.groups` argument.
incidence|>
filter(subpop_pooled == "Two Known Mixed Groups")
## sequence country_code geographic_area reference_date
## 1 4 ARG Five cities 2006-2009
## 2 9 AUS Melbourne 2007-2013
## 3 21 CHN Urumqi 2002-2003
## 4 18 CHN Urumqi 2002-2003
## 5 7 CHN Kunming 2009-2011
## 6 22 CHN Lincang 2011
## 7 9 CHN Kaiyuan 2006-2013
## 8 11 CHN Tianjin 2011-2013
## 9 10 CHN Xichang 2002-2005
## 10 2 CHN Kaiyuan 2006-2013
## 11 8 CHN Urumqi 2003
## 12 6 CHN Urumqi 2001
## 13 6 CHN Kunming 2009-2011
## 14 6 CHN Beijing 2006-2008
## 15 20 CHN Urumqi 2002-2003
## 16 13 CHN Tianjin 2008
## 17 63 IRN 27 prisons 2013
## 18 41 IRN 10 cities 2014
## 19 52 IRN 27 prisons 2009
## 20 50 IRN 27 prisons 2009
## 21 30 IRN 10 cities 2010
## 22 28 IRN 10 cities 2010
## 23 26 IRN 10 cities 2010
## 24 19 IRN 13 cities 2015
## 25 8 IRN 13 cities 2010
## 26 6 IRN 13 cities 2010
## 27 17 IRN 13 cities 2015
## 28 37 IRN 10 cities 2014
## 29 39 IRN 10 cities 2014
## 30 65 IRN 27 prisons 2013
## 31 3 KAZ Almaty & Termirtau 2015-2018
## 32 4 KAZ Almaty & Termirtau 2015-2018
## 33 9 NGA Abuja & Lagos 2013-2018
## 34 12 NGA Abuja & Lagos 2013-2018
## 35 8 RUS St. Petersburg 2009-2010
## 36 7 RUS St. Petersburg 2009-2010
## 37 9 THA Bangkok 2005-2010
## 38 8 THA Bangkok 2005-2010
## 39 14 THA Bangkok 2006-2012
## 40 8 THA Bangkok 2001-2002
## 41 15 THA Bangkok 2006-2012
## 42 9 THA Bangkok 2006-2012
## 43 17 TWN Taiwan 2006-2010
## 44 14 TWN Taiwan 2010
## 45 13 TWN Taiwan 2009
## 46 12 TWN Taiwan 2008
## 47 11 TWN Taiwan 2007
## 48 10 TWN Taiwan 2006
## 49 9 TWN Taiwan 2005
## 50 8 TWN Taiwan 2004
## 51 11 TZA Dar es Salaam 2019
## 52 11 UGA Kampala 2008-2017
## 53 7 UGA Kampala 2009-2011
## subpop subpop_code sex age source_id
## 1 Male sex workers - transgender P M ALL F0365
## 2 IVDU homosexuals/bisexuals I M ALL C1449
## 3 IVDU sex workers I F ALL Z0286
## 4 IVDU sex workers I B ALL Z0286
## 5 Drug user homosexuals & bisexuals I M ALL X0129
## 6 Drug users & prisoners X B ALL Z0575
## 7 Drug user sex workers I F ALL S1647
## 8 Drug user homosexuals I M ALL Y0279
## 9 IVDU STI pts. I B ALL R0558
## 10 Drug user sex workers I F ALL S1586
## 11 Sex workers & clients of sex workers X B ALL J0182
## 12 Sex workers & clients of sex workers X B ALL J0182
## 13 Male sex workers - homosexual/bisexual P M ALL X0129
## 14 Male sex workers - homosexual P M ALL L0985
## 15 IVDU sex workers I M ALL Z0286
## 16 Male sex workers - homosexual P M ALL N0643
## 17 Drug user prisoners I B ALL S1905
## 18 IVDU prisoners I B ALL S1905
## 19 IVDU prisoners I B ALL S1905
## 20 Drug user prisoners I B ALL S1905
## 21 IVDU prisoners I B ALL S1905
## 22 IVDU STI pts. I B ALL S1905
## 23 IVDU homosexuals I M ALL S1905
## 24 IVDU sex workers I F ALL S1905
## 25 IVDU sex workers I F ALL S1905
## 26 Drug user sex workers I F ALL S1905
## 27 Drug user sex workers I F ALL S1905
## 28 IVDU homosexuals I M ALL S1905
## 29 IVDU STI pts. I B ALL S1905
## 30 IVDU prisoners I B ALL S1905
## 31 Drug user sex workers I F ALL E0308
## 32 Drug user sex workers I F ALL E0308
## 33 IVDU homosexuals/bisexuals I M ALL N1055
## 34 Male sex workers - homosexual/bisexual P M ALL N1055
## 35 IVDU sex workers I M ALL K0992
## 36 IVDU sex workers I B ALL K0992
## 37 IVDU homosexuals I M ALL M1599
## 38 IVDU prisoners I B ALL M1599
## 39 Drug user homosexuals I M ALL V0323
## 40 IVDU prisoners I M ALL T0283
## 41 Male sex workers - homosexual P M ALL V0323
## 42 Male sex workers - MSM P M ALL P0641
## 43 IVDU & drug user prisoners I B ALL H0507
## 44 IVDU prisoners I B ALL H0507
## 45 IVDU prisoners I B ALL H0507
## 46 IVDU prisoners I B ALL H0507
## 47 IVDU prisoners I B ALL H0507
## 48 IVDU prisoners I B ALL H0507
## 49 IVDU prisoners I B ALL H0507
## 50 IVDU prisoners I B ALL H0507
## 51 Drug user sex workers I F ALL F0362
## 52 Drug user sex workers I F ALL K1317
## 53 Drug user sex workers I F ALL V0410
## comments
## 1 Cities: Buenos Aires, La Plata, Cordoba, Rosario, & Santiago del Estero. Oct. 06 - Oct. 09. STARHS. Rapid test: Bio-Rad.
## 2 83 person yrs. of observation. Located in Victoria state. Men having sex w/ men (MSM). 1 Jan. 07 - 31 Dec. 13.
## 3 8 person yrs. of observation. Followup at 6 & 12 mos. Located in Xinjiang Autonomous Region.
## 4 55.5 person yrs. of observation. Followup at 6 & 12 mos. Located in Xinjiang Autonomous Region. Breakdown by sex is provided.
## 5 8.2 person yrs. of observation. Located in Yunnan Provnce. Men having sex w/ men (MSM). June 09 - Mar. 11.
## 6 Located in Yunnan Province. BED-CEIA.
## 7 643.5 person yrs. of observation. Located in Yunnan Province.
## 8 120.5 person yrs. of observation. Recruited from a bathhouse. Men having sex w/ men (MSM). Apr. 11 - Sept. 13. Rapid tests: A-WARE, ACON/SD Biolline.
## 9 Located in Sichuan Province. Age 18+. Pts. w/ syphilis. Nov. 02 - 05.
## 10 120.75 person yrs. of observation. Located in Yunnan Province. Mar. 06 - June 13.
## 11 Sentinel surveillance. Located in Xinjiang Autonomous Region.
## 12 Sentinel surveillance. Located in Xinjiang Autonomous Region.
## 13 10.4 person yrs. of observation. Located in Yunnan Provnce. Men having sex w/ men (MSM). June 09 - Mar. 11.
## 14 4.57 person yrs. of observation. Men having sex w/ men (MSM). From Nov. 06.
## 15 47.5 person yrs. of observation. Followup at 6 & 12 mos. Located in Xinjiang Autonomous Region.
## 16 Age range 18-65 yrs. Apr. - June & Oct. - Dec. 08. BED-CEIA.
## 17 144341 person yrs. of observation. Age 18+.
## 18 31590 person yrs. of observation. Age 18+.
## 19 11591 person yrs. of observation. Age 18+.
## 20 47126 person yrs. of observation. Age 18+. Drug use in past yr.
## 21 16163 person yrs. of observation. Age 18+.
## 22 1810 person yrs. of observation. Age 18+.
## 23 2380 person yrs. of observation. Age 18+. Men having sex w/ men (MSM).
## 24 1704 person yrs. of observation. Age 18+. Rapid tests: Determine & Unigold.
## 25 2117 person yrs. of observation. Age 18+.
## 26 9759 person yrs. of observation. Age 18+.
## 27 15395 person yrs. of observation. Age 18+. Rapid tests: Determine & Unigold.
## 28 5469 person yrs. of observation. Age 18+. Men having sex w/ men (MSM).
## 29 3289 person yrs. of observation. Age 18+.
## 30 31394 person yrs. of observation. Age 18+ .
## 31 Only the incidence rate was given. 153.3 person yrs. of observation. Combination HIV Risk Reduction (HIVRR) arm. 6 & 12 mos. follow up. Age 19+. May 15 - Oct. 18.
## 32 Only the incidence rate was given. 153.3 person yrs. of observation. Combination HIV Risk Reduction - Micro Finance (HIVRR-MF) arm. 6 & 12 mos. follow up. Age 19+. May 15 - Oct. 18.
## 33 Only the incidence rate was given. 6 person yrs. of observation. Age 16+. Mar. 13 - Mar. 18. Rapid tests: Determine, Uni-Gold, & Stat Pak.
## 34 Only the incidence rate was given. 180 person yrs. of observation. Had sex in exchange for money or gifts. Age 16+. Mar. 13 - Mar. 18. Rapid tests: Determine, Uni-Gold, & Stat Pak.
## 35
## 36
## 37 112 person yrs. of observation. Sites: 17 drug treatment centers. Since June 05. Also, see C1290.
## 38 1026 person yrs. of observation. Sites: 17 drug treatment centers. Since June 05. Also, see C1290.
## 39 253 PYO. Men having sex w/ men (MSM). Recruited from HIV testing services & entertainment venues: bars, discos, & saunas. At baseline. Rapid tests: OraQuick, Determine, Double Check/SD-Bioline, & Capillus/Core.
## 40 81.08 person yrs. of observation. Klong Prem Central Prison Medical Correctional Institution. Followed up 5 mos. June 01 - Aug. 02.
## 41 310 PYO. Men having sex w/ men (MSM). Recruited from HIV testing services & entertainment venues: bars, discos, & saunas. At baseline. Rapid tests: OraQuick, Determine, Double Check/SD-Bioline, & Capillus/Core.
## 42 Only the incidence rate was given. 301 person yrs. of observation. MSM=Men having sex w/ men. Age 18+. 6 Apr. 06 - 20 Mar. 12. Rapid tests: Determine, DoubleCheck or SDBioline, & Capillus.
## 43 5670 person yrs. of observation.
## 44 1 Jan. - 31 Dec. 10. BED-CEIA.
## 45 1 Jan. - 31 Dec. 09. BED-CEIA.
## 46 1 Jan. - 31 Dec. 08. BED-CEIA.
## 47 1 Jan. - 31 Dec. 07. BED-CEIA.
## 48 1 Jan. - 31 Dec. 06. BED-CEIA.
## 49 1 Jan. - 31 Dec. 05. BED-CEIA.
## 50 1 Jan. - 31 Dec. 04. BED-CEIA.
## 51 Only the incidence rate was given. 71 person yrs. of observations. Respondent-driven sampling (RDS). Rapid tests: SD Bioline & Uni-Gold.
## 52 1260 person yrs. of observation. Mar. 08 - 29 Aug. 17. Rapid tests: Determine, Stat-Pak, & Uni-Gold.
## 53 Only the incidence rate was given. 253 person yrs. of observation. Apr. 08 - Mar. 11.
## data_type country site_name
## 1 I Argentina Five cities
## 2 I Australia Melbourne Sexual Health Centre
## 3 I China, Mainland Urumqi
## 4 I China, Mainland Urumqi
## 5 I China, Mainland Kunming
## 6 I China, Mainland Lincang
## 7 I China, Mainland Kaiyuan
## 8 I China, Mainland Tianjin
## 9 I China, Mainland Xichang
## 10 I China, Mainland Kaiyuan
## 11 I China, Mainland Urumqi
## 12 I China, Mainland Urumqi
## 13 I China, Mainland Kunming
## 14 I China, Mainland Beijing
## 15 I China, Mainland Urumqi
## 16 I China, Mainland Tianjin
## 17 I Iran 27 prisons
## 18 I Iran 10 cities
## 19 I Iran 27 prisons
## 20 I Iran 27 prisons
## 21 I Iran 10 cities
## 22 I Iran 10 cities
## 23 I Iran 10 cities
## 24 I Iran 13 cities
## 25 I Iran 13 cities
## 26 I Iran 13 cities
## 27 I Iran 13 cities
## 28 I Iran 10 cities
## 29 I Iran 10 cities
## 30 I Iran 27 prisons
## 31 I Kazakhstan Almaty, Termirtau
## 32 I Kazakhstan Almaty, Termirtau
## 33 I Nigeria Abuja, Lagos
## 34 I Nigeria Abuja, Lagos
## 35 I Russia St. Petersburg
## 36 I Russia St. Petersburg
## 37 I Thailand 17 sites
## 38 I Thailand 17 sites
## 39 I Thailand Bangkok
## 40 I Thailand Klong Prem Central Prison
## 41 I Thailand Bangkok
## 42 I Thailand Silom Community clinic
## 43 I China, Taiwan Taiwan
## 44 I China, Taiwan Taiwan
## 45 I China, Taiwan Taiwan
## 46 I China, Taiwan Taiwan
## 47 I China, Taiwan Taiwan
## 48 I China, Taiwan Taiwan
## 49 I China, Taiwan Taiwan
## 50 I China, Taiwan Taiwan
## 51 I Tanzania Muhimbili University of Health and Allied Sciences
## 52 I Uganda One clinic
## 53 I Uganda One clinic
## author year
## 1 Farias, M. S. R., M. N. Garcia, E. Reynaga, et al. 2011
## 2 Cheung, K. T., C. K. Fairley, T. R. H. Read, et al. 2016
## 3 Zhang, Y., H. Shan, J. Trizzino, et al. 2007
## 4 Zhang, Y., H. Shan, J. Trizzino, et al. 2007
## 5 Xu, J., M. An, X. Han, et al. 2013
## 6 Zhu, Q., C. Yang, Z. Li, et al. 2015
## 7 Su, Y., G. Ding, K. H. Reilly, et al. 2016
## 8 Yu, M., G. Jiang, Z. Dou, et al. 2016
## 9 Ruan, Y., G. Qin, L. Yin, et al. 2007
## 10 Su, Y., G. Ding, H. Liu, et al. 2015
## 11 Joseph, O., M. Zhang, L. J. Zhang 2005
## 12 Joseph, O., M. Zhang, L. J. Zhang 2005
## 13 Xu, J., M. An, X. Han, et al. 2013
## 14 Li, D., Y. Jia, Y. Ruan, et al. 2010
## 15 Zhang, Y., H. Shan, J. Trizzino, et al. 2007
## 16 Ning, T. L., Y. Guo, Z. Q. Liu, et al. 2011
## 17 Sharifi, H., A. Mirzazadeh, M. Shokoohi, et al. 2018
## 18 Sharifi, H., A. Mirzazadeh, M. Shokoohi, et al. 2018
## 19 Sharifi, H., A. Mirzazadeh, M. Shokoohi, et al. 2018
## 20 Sharifi, H., A. Mirzazadeh, M. Shokoohi, et al. 2018
## 21 Sharifi, H., A. Mirzazadeh, M. Shokoohi, et al. 2018
## 22 Sharifi, H., A. Mirzazadeh, M. Shokoohi, et al. 2018
## 23 Sharifi, H., A. Mirzazadeh, M. Shokoohi, et al. 2018
## 24 Sharifi, H., A. Mirzazadeh, M. Shokoohi, et al. 2018
## 25 Sharifi, H., A. Mirzazadeh, M. Shokoohi, et al. 2018
## 26 Sharifi, H., A. Mirzazadeh, M. Shokoohi, et al. 2018
## 27 Sharifi, H., A. Mirzazadeh, M. Shokoohi, et al. 2018
## 28 Sharifi, H., A. Mirzazadeh, M. Shokoohi, et al. 2018
## 29 Sharifi, H., A. Mirzazadeh, M. Shokoohi, et al. 2018
## 30 Sharifi, H., A. Mirzazadeh, M. Shokoohi, et al. 2018
## 31 El-Bassel, N., T. McCrimmon, G. Mergenova, et al. 2021
## 32 El-Bassel, N., T. McCrimmon, G. Mergenova, et al. 2021
## 33 Nowak, R. G., A. Mitchell, T. A. Crowell, et al. 2019
## 34 Nowak, R. G., A. Mitchell, T. A. Crowell, et al. 2019
## 35 Kozlov, A. P., R. V. Skochilov, O. V. Toussova, et al. 2016
## 36 Kozlov, A. P., R. V. Skochilov, O. V. Toussova, et al. 2016
## 37 Martin, M., S. Vanichseni, P. Suntharasamai, et al. 2014
## 38 Martin, M., S. Vanichseni, P. Suntharasamai, et al. 2014
## 39 van Griensven, F., W. Thienkrua, J. McNicholl, et al. 2013
## 40 Thaisri, H., J. Lerwitworapong, S. Vongsheree, et al. 2003
## 41 van Griensven, F., W. Thienkrua, J. McNicholl, et al. 2013
## 42 Piyaraj, P., P. F. van Griensven, T. H. Holtz, et al. 2018
## 43 Huang, Y., J. Yang, K. E. Nelson, et al. 2014
## 44 Huang, Y., J. Yang, K. E. Nelson, et al. 2014
## 45 Huang, Y., J. Yang, K. E. Nelson, et al. 2014
## 46 Huang, Y., J. Yang, K. E. Nelson, et al. 2014
## 47 Huang, Y., J. Yang, K. E. Nelson, et al. 2014
## 48 Huang, Y., J. Yang, K. E. Nelson, et al. 2014
## 49 Huang, Y., J. Yang, K. E. Nelson, et al. 2014
## 50 Huang, Y., J. Yang, K. E. Nelson, et al. 2014
## 51 Faini, D., F. Msafiri, P. Munseri, et al. 2022
## 52 Kasamba, I., S. Nash, M. Shahmanesh, et al. 2019
## 53 Vandepitte, J., H. A. Weiss, J. Bukenya, et al. 2013
## title
## 1 First Report on Sexually Transmitted Infections among Trans (Male to Female Transvestites, Transsexuals, or Transgender) and ...
## 2 HIV Incidence and Predictors of Incident HIV among Men Who Have Sex with Men Attending a Sexual Health Clinic in ...
## 3 HIV Incidence, Retention Rate, and Baseline Predictors of HIV Incidence and Retention in a Prospective Cohort Study of ...
## 4 HIV Incidence, Retention Rate, and Baseline Predictors of HIV Incidence and Retention in a Prospective Cohort Study of ...
## 5 Prospective Cohort Study of HIV Incidence and Molecular Characteristics of HIV among Men Who Have Sex with Men (MSM) in ...
## 6 Estimation of Infection Rate of HIV-1 in Different Populations in Lincang City in 2011 with BED-CEIA Assay
## 7 Loss to Follow-Up and HIV Incidence in Female Sex Workers in Kaiyuan, Yunnan Province China: A Nine Year Longitudinal Study
## 8 HIV Infection Incidence among Men Who Have Sex with Men in Common Bathing Pool in Tianjin: A Cohort Study
## 9 Incidence of HIV, Hepatitis C and Hepatitis B Viruses among Injection Drug Users in Southwestern China: A 3-Year Follow-up Study
## 10 Influencing Factors for Loss to Follow-Up in a Longitudinal Study on HIV Incidence of Female Sex Workers
## 11 Analysis of HIV/AIDS Surveillance in Urumqi from 2000 to 2003
## 12 Analysis of HIV/AIDS Surveillance in Urumqi from 2000 to 2003
## 13 Prospective Cohort Study of HIV Incidence and Molecular Characteristics of HIV among Men Who Have Sex with Men (MSM) in ...
## 14 Correlates of Incident Infections for HIV, Syphilis, and Hepatitis B Virus in a Cohort of Men Who Have Sex with Men in Beijing
## 15 HIV Incidence, Retention Rate, and Baseline Predictors of HIV Incidence and Retention in a Prospective Cohort Study of ...
## 16 Survey on Recent HIV Infection among Men Who Have Sex with Men in Tianjin during 2008-2009
## 17 Estimation of HIV Incidence and Its Trend in Three Key Populations in Iran
## 18 Estimation of HIV Incidence and Its Trend in Three Key Populations in Iran
## 19 Estimation of HIV Incidence and Its Trend in Three Key Populations in Iran
## 20 Estimation of HIV Incidence and Its Trend in Three Key Populations in Iran
## 21 Estimation of HIV Incidence and Its Trend in Three Key Populations in Iran
## 22 Estimation of HIV Incidence and Its Trend in Three Key Populations in Iran
## 23 Estimation of HIV Incidence and Its Trend in Three Key Populations in Iran
## 24 Estimation of HIV Incidence and Its Trend in Three Key Populations in Iran
## 25 Estimation of HIV Incidence and Its Trend in Three Key Populations in Iran
## 26 Estimation of HIV Incidence and Its Trend in Three Key Populations in Iran
## 27 Estimation of HIV Incidence and Its Trend in Three Key Populations in Iran
## 28 Estimation of HIV Incidence and Its Trend in Three Key Populations in Iran
## 29 Estimation of HIV Incidence and Its Trend in Three Key Populations in Iran
## 30 Estimation of HIV Incidence and Its Trend in Three Key Populations in Iran
## 31 A Cluster-Randomized Controlled Trial of a Combination HIV Risk Reduction and Microfinance Intervention for Female Sex Workers Who Use Drugs in Kazakhstan
## 32 A Cluster-Randomized Controlled Trial of a Combination HIV Risk Reduction and Microfinance Intervention for Female Sex Workers Who Use Drugs in Kazakhstan
## 33 Individual and Sexual Network Predictors of HIV Incidence among Men Who Have Sex with Men in Nigeria
## 34 Individual and Sexual Network Predictors of HIV Incidence among Men Who Have Sex with Men in Nigeria
## 35 HIV Incidence and Behavioral Correlates of HIV Acquisition in a Cohort of Injection Drug Users in St Petersburg, Russia
## 36 HIV Incidence and Behavioral Correlates of HIV Acquisition in a Cohort of Injection Drug Users in St Petersburg, Russia
## 37 Risk Behaviors and Risk Factors for HIV Infection among Participants in the Bangkok Tenofovir Study, an HIV Pre-Exposure ...
## 38 Risk Behaviors and Risk Factors for HIV Infection among Participants in the Bangkok Tenofovir Study, an HIV Pre-Exposure ...
## 39 Evidence of an Explosive Epidemic of HIV Infection in a Cohort of Men Who Have Sex with Men in Thailand
## 40 HIV Infection and Risk Factors among Bangkok Prisoners, Thailand: A Prospective Cohortr Study
## 41 Evidence of an Explosive Epidemic of HIV Infection in a Cohort of Men Who Have Sex with Men in Thailand
## 42 The Finding of Casual Sex Partners on the Internet, Methamphetamine Use for Sexual Pleasure, and Incidence of HIV Infection among Men Who Have Sex with Men in Bangkok, Thailand: An Observational Cohort Study
## 43 Changes in HIV Incidence among People Who Inject Drugs in Taiwan Following Introduction of a Harm Reduction Program: A Study ...
## 44 Changes in HIV Incidence among People Who Inject Drugs in Taiwan Following Introduction of a Harm Reduction Program: A Study ...
## 45 Changes in HIV Incidence among People Who Inject Drugs in Taiwan Following Introduction of a Harm Reduction Program: A Study ...
## 46 Changes in HIV Incidence among People Who Inject Drugs in Taiwan Following Introduction of a Harm Reduction Program: A Study ...
## 47 Changes in HIV Incidence among People Who Inject Drugs in Taiwan Following Introduction of a Harm Reduction Program: A Study ...
## 48 Changes in HIV Incidence among People Who Inject Drugs in Taiwan Following Introduction of a Harm Reduction Program: A Study ...
## 49 Changes in HIV Incidence among People Who Inject Drugs in Taiwan Following Introduction of a Harm Reduction Program: A Study ...
## 50 Changes in HIV Incidence among People Who Inject Drugs in Taiwan Following Introduction of a Harm Reduction Program: A Study ...
## 51 The Prevalence, Incidence, and Risk Factors for HIV among Female Sex Workers - A Cohort being Prepared for a Phase IIb HIV Vaccine Trial in Dar es Salaam, Tanzania
## 52 Missed Study Visits and Subsequent HIV Incidence among Women in a Predominantly Sex Worker Cohort Attending a Dedicated Clinic Service in Kampala, Uganda
## 53 Alcohol Use, Mycoplasma Genitalium, and Other STIs Associated with HIV Incidence among Women at High Risk in Kampala, Uganda
## publication_information
## 1 International Journal of Infectious Diseases, vol. 15, issue 9, pp. e635-e640, <http://www.ijidonline.com>, accessed on January 23, 2014.
## 2 PLoS One, vol. 11, no. 5, e0156160, <http://www.plosone.org>, accessed on May 31, 2016.
## 3 International Journal of Infectious Diseases, vol. 11, pp. 318-323.
## 4 International Journal of Infectious Diseases, vol. 11, pp. 318-323.
## 5 BMC Infectious Disease, vol. 13, no. 3, pp. 1-10, <http://www.biomedcentral.com/1471-2334/13/3>, accessed on May 27, 2014.
## 6 China Tropical Medicine, vol. 15, no. 2, pp. 170-172.
## 7 BMC Infectious Diseases, vol. 16, article no. 526, <http://www.bmcinfectdis.biomedcentral.com>, accessed on October 6, 2016.
## 8 Chinese Journal of Epidemiology, vol. 37, no. 3, pp. 362-366.
## 9 AIDS, vol. 21, suppl. 8, pp. S39-S46.
## 10 Chinese Journal of Epidemiology, vol. 36, no. 3, pp. 250-253.
## 11 Chinese Journal of AIDS and STD, vol. 11, no. 1, p. 40.
## 12 Chinese Journal of AIDS and STD, vol. 11, no. 1, p. 40.
## 13 BMC Infectious Disease, vol. 13, no. 3, pp. 1-10, <http://www.biomedcentral.com/1471-2334/13/3>, accessed on May 27, 2014.
## 14 AIDS Patient Care and STDs, vol. 24, no. 9, pp. 595-602.
## 15 International Journal of Infectious Diseases, vol. 11, pp. 318-323.
## 16 Chinese Journal of Epidemiology, vol. 32, no. 11, pp. 1087-1090.
## 17 PLoS One, vol. 13, no. 11, e0207681, pp. 1-13, <http://doi.org/10.1371/journal.pone.0207681>, accessed on December 29, 2018.
## 18 PLoS One, vol. 13, no. 11, e0207681, pp. 1-13, <http://doi.org/10.1371/journal.pone.0207681>, accessed on December 29, 2018.
## 19 PLoS One, vol. 13, no. 11, e0207681, pp. 1-13, <http://doi.org/10.1371/journal.pone.0207681>, accessed on December 29, 2018.
## 20 PLoS One, vol. 13, no. 11, e0207681, pp. 1-13, <http://doi.org/10.1371/journal.pone.0207681>, accessed on December 29, 2018.
## 21 PLoS One, vol. 13, no. 11, e0207681, pp. 1-13, <http://doi.org/10.1371/journal.pone.0207681>, accessed on December 29, 2018.
## 22 PLoS One, vol. 13, no. 11, e0207681, pp. 1-13, <http://doi.org/10.1371/journal.pone.0207681>, accessed on December 29, 2018.
## 23 PLoS One, vol. 13, no. 11, e0207681, pp. 1-13, <http://doi.org/10.1371/journal.pone.0207681>, accessed on December 29, 2018.
## 24 PLoS One, vol. 13, no. 11, e0207681, pp. 1-13, <http://doi.org/10.1371/journal.pone.0207681>, accessed on December 29, 2018.
## 25 PLoS One, vol. 13, no. 11, e0207681, pp. 1-13, <http://doi.org/10.1371/journal.pone.0207681>, accessed on December 29, 2018.
## 26 PLoS One, vol. 13, no. 11, e0207681, pp. 1-13, <http://doi.org/10.1371/journal.pone.0207681>, accessed on December 29, 2018.
## 27 PLoS One, vol. 13, no. 11, e0207681, pp. 1-13, <http://doi.org/10.1371/journal.pone.0207681>, accessed on December 29, 2018.
## 28 PLoS One, vol. 13, no. 11, e0207681, pp. 1-13, <http://doi.org/10.1371/journal.pone.0207681>, accessed on December 29, 2018.
## 29 PLoS One, vol. 13, no. 11, e0207681, pp. 1-13, <http://doi.org/10.1371/journal.pone.0207681>, accessed on December 29, 2018.
## 30 PLoS One, vol. 13, no. 11, e0207681, pp. 1-13, <http://doi.org/10.1371/journal.pone.0207681>, accessed on December 29, 2018.
## 31 Journal of the International AIDS Society, vol. 24, issue 5, article no. e25682, <https://doi.org/10.1002/jia2.25682>, accessed on October 3, 2022.
## 32 Journal of the International AIDS Society, vol. 24, issue 5, article no. e25682, <https://doi.org/10.1002/jia2.25682>, accessed on October 3, 2022.
## 33 Journal of Acquired Immune Deficiency Syndrome, vol. 80, no. 4, pp. 444-453, <https://doi.org/10.1097/QAI.0000000000001934>, accessed on March 12, 2019.
## 34 Journal of Acquired Immune Deficiency Syndrome, vol. 80, no. 4, pp. 444-453, <https://doi.org/10.1097/QAI.0000000000001934>, accessed on March 12, 2019.
## 35 Medicine, vol. 95, no. 44, e5238, <http://dx.doi.org/10.1097/MD.0000000000005238>, accessed on May 31, 2019.
## 36 Medicine, vol. 95, no. 44, e5238, <http://dx.doi.org/10.1097/MD.0000000000005238>, accessed on May 31, 2019.
## 37 PLoS One, vol. 9, issue 3, e92809, pp. 1-7, <http://www.plosone.org>, accessed on July 16, 2014.
## 38 PLoS One, vol. 9, issue 3, e92809, pp. 1-7, <http://www.plosone.org>, accessed on July 16, 2014.
## 39 AIDS, vol. 27, no. 5, pp. 825-832.
## 40 BMC Infectious Diseases, vol. 3, no. 25, <http://www.biomedcentral.com/1471-2334/3/25>, accessed on November 3, 2003.
## 41 AIDS, vol. 27, no. 5, pp. 825-832.
## 42 Lancet HIV, vol. 5, no. 7, pp. e379-e389, <https://doi.org/10.1016/S2352-3018(18)30065-1>, accessed on October 3, 2022.
## 43 PLoS Medicine, vol. 11, issue 4, e1001625, pp. 1-12, <http://www.plosmedicine.org>, accessed on May 09, 2014.
## 44 PLoS Medicine, vol. 11, issue 4, e1001625, pp. 1-12, <http://www.plosmedicine.org>, accessed on May 09, 2014.
## 45 PLoS Medicine, vol. 11, issue 4, e1001625, pp. 1-12, <http://www.plosmedicine.org>, accessed on May 09, 2014.
## 46 PLoS Medicine, vol. 11, issue 4, e1001625, pp. 1-12, <http://www.plosmedicine.org>, accessed on May 09, 2014.
## 47 PLoS Medicine, vol. 11, issue 4, e1001625, pp. 1-12, <http://www.plosmedicine.org>, accessed on May 09, 2014.
## 48 PLoS Medicine, vol. 11, issue 4, e1001625, pp. 1-12, <http://www.plosmedicine.org>, accessed on May 09, 2014.
## 49 PLoS Medicine, vol. 11, issue 4, e1001625, pp. 1-12, <http://www.plosmedicine.org>, accessed on May 09, 2014.
## 50 PLoS Medicine, vol. 11, issue 4, e1001625, pp. 1-12, <http://www.plosmedicine.org>, accessed on May 09, 2014.
## 51 Journal of Acquired Immune Deficiency Syndromes, vol. 91, no. 5, pp. 439-448, <https://www.ncbi.nlm.nih.gov/pmc/articles/PMC9646411/>, accessed on November 9, 2022.
## 52 Journal of Acquired Immune Deficiency Syndrome, vol. 82, no. 4, pp. 343-354, <https://doi.org/10.1097/QAI0000000000002143>, accessed on February 12, 2021.
## 53 Journal of Acquired Immune Deficiency Syndrome, vol. 62, no. 1, pp. 119-126, <https://doi.org/10.1097/QAI.0b013e3182777167>, accessed on July 25, 2019.
## virus_type inc_rate specimen_type test_type sampsize
## 1 HIV 10.70 BW ELISA, RAPID, WB 259
## 2 HIV 8.43 B ELISA, WB N/A
## 3 HIV1 0.00 BW ELISA, WB 8
## 4 HIV1 14.40 BW ELISA, WB 57
## 5 HIV 0.00 BW ELISA*2, WB N/A
## 6 HIV1 0.21 B ELISA 37
## 7 HIV1 2.02 BW ELISA*2, WB 186
## 8 HIV 6.64 BW RAPID*2, WB N/A
## 9 HIV 1.70 BW ELISA, WB 44
## 10 HIV 4.14 B ELISA*2, WB 35
## 11 HIV 0.77 B UNK 130
## 12 HIV 0.38 B UNK 261
## 13 HIV 0.00 BW ELISA*2, WB N/A
## 14 HIV 25.13 BW ELISA, WB N/A
## 15 HIV1 16.80 BW ELISA, WB 49
## 16 HIV 4.20 BW ELISA, WB 178
## 17 HIV 0.05 BS ELISA*2 N/A
## 18 HIV 0.57 BS ELISA*2 N/A
## 19 HIV 0.47 BS ELISA*2 N/A
## 20 HIV 0.16 BS ELISA*2 N/A
## 21 HIV 1.87 BS ELISA*2 N/A
## 22 HIV 2.04 BS ELISA*2 N/A
## 23 HIV 1.58 BS ELISA*2 N/A
## 24 HIV 0.41 BS RAPID*2 N/A
## 25 HIV 0.47 BS ELISA*2 N/A
## 26 HIV 0.24 BS ELISA*2 N/A
## 27 HIV 0.14 BS RAPID*2 N/A
## 28 HIV 0.42 BS ELISA*2 N/A
## 29 HIV 0.70 BS ELISA*2 N/A
## 30 HIV 0.17 BS ELISA*2 N/A
## 31 HIV 0.65 B UNK N/A
## 32 HIV 0.00 B UNK N/A
## 33 HIV 54.91 B RAPID*3 N/A
## 34 HIV 19.48 B RAPID*3 N/A
## 35 HIV1 11.10 BW ELISA, WB 17
## 36 HIV1 9.70 BW ELISA, WB 19
## 37 HIV 0.00 O UNK N/A
## 38 HIV 1.46 O UNK N/A
## 39 HIV 11.50 BW RAPID*4 N/A
## 40 HIV1 11.10 B ELISA, WB 351
## 41 HIV 7.40 BW RAPID*4 N/A
## 42 HIV 7.31 BW RAPID*3 N/A
## 43 HIV 0.00 BW UNK N/A
## 44 HIV 0.27 BW ELISA 64
## 45 HIV 0.29 BW ELISA 107
## 46 HIV 0.85 BW ELISA 244
## 47 HIV 1.84 BW ELISA 545
## 48 HIV 11.58 BW ELISA 1,413
## 49 HIV 18.16 BW ELISA 1,363
## 50 HIV 6.44 BW ELISA 115
## 51 HIV 4.25 BW RAPID*2, ELISA*2 N/A
## 52 HIV 3.81 B RAPID, ELISA*2, WB/RAPID*3 N/A
## 53 HIV1 4.35 BW ELISA*2 N/A
## subpop_pooled
## 1 Two Known Mixed Groups
## 2 Two Known Mixed Groups
## 3 Two Known Mixed Groups
## 4 Two Known Mixed Groups
## 5 Two Known Mixed Groups
## 6 Two Known Mixed Groups
## 7 Two Known Mixed Groups
## 8 Two Known Mixed Groups
## 9 Two Known Mixed Groups
## 10 Two Known Mixed Groups
## 11 Two Known Mixed Groups
## 12 Two Known Mixed Groups
## 13 Two Known Mixed Groups
## 14 Two Known Mixed Groups
## 15 Two Known Mixed Groups
## 16 Two Known Mixed Groups
## 17 Two Known Mixed Groups
## 18 Two Known Mixed Groups
## 19 Two Known Mixed Groups
## 20 Two Known Mixed Groups
## 21 Two Known Mixed Groups
## 22 Two Known Mixed Groups
## 23 Two Known Mixed Groups
## 24 Two Known Mixed Groups
## 25 Two Known Mixed Groups
## 26 Two Known Mixed Groups
## 27 Two Known Mixed Groups
## 28 Two Known Mixed Groups
## 29 Two Known Mixed Groups
## 30 Two Known Mixed Groups
## 31 Two Known Mixed Groups
## 32 Two Known Mixed Groups
## 33 Two Known Mixed Groups
## 34 Two Known Mixed Groups
## 35 Two Known Mixed Groups
## 36 Two Known Mixed Groups
## 37 Two Known Mixed Groups
## 38 Two Known Mixed Groups
## 39 Two Known Mixed Groups
## 40 Two Known Mixed Groups
## 41 Two Known Mixed Groups
## 42 Two Known Mixed Groups
## 43 Two Known Mixed Groups
## 44 Two Known Mixed Groups
## 45 Two Known Mixed Groups
## 46 Two Known Mixed Groups
## 47 Two Known Mixed Groups
## 48 Two Known Mixed Groups
## 49 Two Known Mixed Groups
## 50 Two Known Mixed Groups
## 51 Two Known Mixed Groups
## 52 Two Known Mixed Groups
## 53 Two Known Mixed Groups
# prevalence
prevalence <- read.csv("surveillance/data/hiv_prevalence.csv") |>
janitor::clean_names() |>
select(-c(no_cases,no_deaths,inc_rate))|>
rename(subpop = population_subgroup)
# Histogram for HIV incidences
incidence |>
ggplot(aes(x = inc_rate)) + geom_histogram(binwidth = 1, fill = "blue", color = "black")
# add a small constant 0.01 to each value and conduct log transformation
log_inc = log(pull(incidence,inc_rate)+0.01)
incidence |>
ggplot(aes(x = log_inc)) + geom_histogram(binwidth = 1, fill = "blue", color = "black")
# Histogram for HIV prevalences
POR = log(pull(prevalence,prev_rate)/(1-pull(prevalence,prev_rate)))
## Warning in log(pull(prevalence, prev_rate)/(1 - pull(prevalence, prev_rate))):
## NaNs produced
prevalence |>
ggplot(aes(x = prev_rate)) + geom_histogram(binwidth = 1, fill = "blue", color = "black")
# add a small constant 0.01 to each value and conduct log transformation
log_prev = log(pull(prevalence,prev_rate)+0.01)
prevalence |>
ggplot(aes(x = log_prev)) + geom_histogram(binwidth = 1, fill = "blue", color = "black")
tri = (pull(prevalence,prev_rate))^(1/2)
prevalence |>
ggplot(aes(x = tri)) + geom_histogram(binwidth = 1, fill = "blue", color = "black")
# Load necessary libraries
library(broom) # For tidy statistical summaries
# ANOVA for numeric variables (e.g., age)
aov_prev = aov(prev_rate ~ sex, data = prevalence) |> broom::tidy()
aov_inc = aov(inc_rate ~ sex, data = incidence) |> broom::tidy()
print(glue::glue("\nANOVA for HIV Prevalence Rate by Age:\n"))
## ANOVA for HIV Prevalence Rate by Age:
print(aov_prev)
## # A tibble: 2 × 6
## term df sumsq meansq statistic p.value
## <chr> <dbl> <dbl> <dbl> <dbl> <dbl>
## 1 sex 2 18776. 9388. 37.0 8.93e-17
## 2 Residuals 61023 15493264. 254. NA NA
print(glue::glue("\nANOVA for HIV Incidence Rate by Age:\n"))
## ANOVA for HIV Incidence Rate by Age:
print(aov_inc)
## # A tibble: 2 × 6
## term df sumsq meansq statistic p.value
## <chr> <dbl> <dbl> <dbl> <dbl> <dbl>
## 1 sex 2 555. 278. 12.3 0.00000455
## 2 Residuals 3726 83838. 22.5 NA NA
# t test: Difference in HIV incidence rate between the circumcised and uncircumcised
circumcise =
incidence |>
mutate(
subpop = recode(subpop,
'Adults - circumcised' = 'circumcised',
'Adults - uncircumcised' = 'uncircumcised')) |>
filter(subpop %in% c('circumcised','uncircumcised'))
ttest_result = t.test(inc_rate ~ subpop, data = circumcise) |> broom::tidy()
print(glue::glue("\nT-Test for HIV incidence by circumcision status among adults:\n"))
## T-Test for HIV incidence by circumcision status among adults:
print(ttest_result)
## # A tibble: 1 × 10
## estimate estimate1 estimate2 statistic p.value parameter conf.low conf.high
## <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl>
## 1 -1.24 1.10 2.34 -2.16 0.0397 26.7 -2.42 -0.0631
## # ℹ 2 more variables: method <chr>, alternative <chr>
According to the results of ttest, we have sufficient evidence to conclude that there’s difference in incidence rate between the circumcised and uncircumcised adults. the uncircumcised adults are more likely to get HIV compared with the circumcised adults.
library(plotly)
##
## Attaching package: 'plotly'
## The following object is masked from 'package:ggplot2':
##
## last_plot
## The following object is masked from 'package:stats':
##
## filter
## The following object is masked from 'package:graphics':
##
## layout
library(ggplot2)
# A map reports the HIV prevalence and incidence rates in each country
map_inc = incidence |>
plot_ly(type = 'choropleth', locations = ~country_code,
z = ~inc_rate, text = ~paste(country, ': ', inc_rate, '%'),
hoverinfo = 'text',color = ~inc_rate, colors = "Reds") |>
layout(title = 'HIV Incidence Rates by country',
geo = list(projection = list(type = 'orthographic')))
map_inc
map_prev = prevalence |>
plot_ly(type = 'choropleth', locations = ~country_code,
z = ~prev_rate, text = ~paste(country, ': ', prev_rate, '%'),
hoverinfo = 'text',color = ~prev_rate, colors = "Reds") |>
layout(title = 'HIV Prevalence Rates by country',
geo = list(projection = list(type = 'orthographic')))
map_prev
# HIV Incidence Rates by circumcision status among adults
circumcise_plot = circumcise |>
plot_ly(x = ~subpop, y = ~inc_rate, type = 'box') |>
layout(title = 'HIV Incidence Rates by circumcision status among adults',
yaxis = list(title = 'Incidence Rate(%)'),
xaxis = list(title = 'Circumcision Status'))
circumcise_plot
# Difference in HIV Prevalence and Incidence Rates Across Gender
prev_sex = prevalence |>
group_by(sex) |>
summarize(median=median(prev_rate), n = n()) |>
mutate(text_label = str_c("Sex:", sex, " \nMedian:", median, " Sample Size:", n))
sex_plot = incidence |>
group_by(sex) |>
summarise(median = median(inc_rate), n = n()) |>
mutate(text_label = str_c("Sex:", sex, " \nMedian:", median, " Sample Size:", n)) |>
plot_ly(x = ~sex, y = ~median, size = ~n, type = 'scatter', mode = 'markers', name = 'Incidence Rate',text = ~text_label, hoverinfo = 'text') |>
add_trace(data = prev_sex, x = ~sex, y = ~median, size = ~n, type = 'scatter', name = 'Prevalence Rate',text = ~text_label, hoverinfo = 'text') |>
layout(title = 'Median Incidence and Prevalence Rates by Sex',
xaxis = list(title = 'Sex'),
yaxis = list(title = 'Median Rate'))
print(sex_plot)
## Warning: `line.width` does not currently support multiple values.
## Warning: `line.width` does not currently support multiple values.
# HIV Prevalence and Incidence Rates by Country
inc_country = incidence |>
group_by(country) |>
summarize(median = median(inc_rate)) |>
mutate(country = fct_reorder(country, median)) |>
plot_ly(x = ~country, y = ~median, type = 'scatter', mode = 'markers') |>
layout(title = 'HIV Incidence Rates by Country',
yaxis = list(title = 'Incidence Rate(%)'))
inc_country
prev_country = prevalence |>
group_by(country) |>
summarize(median = median(prev_rate)) |>
mutate(country = fct_reorder(country, median)) |>
plot_ly(x = ~country, y = ~median, type = 'scatter', mode = 'markers') |>
layout(title = 'HIV Prevalence Rates by Country',
yaxis = list(title = 'Prevalence Rate(%)'))
prev_country
# HIV Prevalence and Incidence Rates of Each Subpopulation Over Time
year_subpop_inc_plot = incidence |>
group_by(subpop_pooled,year) |>
summarise(median = median(inc_rate)) |>
plot_ly(x = ~year, y = ~median, color = ~subpop_pooled, type = 'scatter', mode = 'lines') |>
layout(title = 'HIV Incidence Rates of Each Subpopulation Over Year')
## `summarise()` has grouped output by 'subpop_pooled'. You can override using the
## `.groups` argument.
print(year_subpop_inc_plot)
# Load necessary libraries
library(dplyr)
library(knitr)
# Top 10 countries with the highest incidence
top_inc = incidence |>
group_by(country) |>
summarize(median = median(inc_rate)) |>
arrange(desc(median)) |>
top_n(10)
## Selecting by median
# Top 10 countries with the highest prevalence
top_prev = prevalence |>
group_by(country) |>
summarize(median = median(prev_rate)) |>
arrange(desc(median)) |>
top_n(10)
## Selecting by median
# Display the tables with kable for a professional look
kable(top_inc, caption = "Top 10 Countries with Highest HIV Incidence Rates",
format = "html", table.attr = "style='width:100%;'",
col.names = c("Country", "Median Incidence Rate"))
| Country | Median Incidence Rate |
|---|---|
| Estonia | 26.100 |
| Ukraine | 24.760 |
| Israel | 18.290 |
| Nicaragua | 14.400 |
| Pakistan | 12.450 |
| Burma | 10.100 |
| Mexico | 9.400 |
| Uruguay | 8.165 |
| Russia | 7.200 |
| Gambia, The | 6.925 |
kable(top_prev, caption = "Top 10 Countries with Highest HIV Prevalence Rates",
format = "html", table.attr = "style='width:100%;'",
col.names = c("Country", "Median Prevalence Rate"))
| Country | Median Prevalence Rate |
|---|---|
| Qatar | 38.460 |
| Eswatini | 29.755 |
| Burundi | 29.355 |
| Zambia | 21.070 |
| Botswana | 20.875 |
| Mauritius | 19.780 |
| Zimbabwe | 19.290 |
| Malawi | 18.950 |
| Uzbekistan | 18.200 |
| Guyana | 17.765 |